require "TableDials"

DialPanel = {};
local this = DialPanel
local luaBehaviour
local transform;
local gameObject;

--启动事件--
function DialPanel.Awake(obj)
	gameObject = obj;
	transform = obj.transform;

	this.InitPanel();
	
	luaBehaviour = gameObject:GetComponent('LuaBehaviour');
	logWarn("DialPanel Awake lua--->>"..gameObject.name);
end

function DialPanel.Start()
	logWarn("DialPanel Start")

end

--初始化面板--
function DialPanel.InitPanel()
	this.back = transform:Find("Back").gameObject
	this.start = transform:Find("Start").gameObject
	this.title = transform:Find("Title").gameObject
	UIEvent.AddButtonClick(this.back,BackClick)
	UIEvent.AddButtonClick(this.start,StartClick)
	print(this.start)
	print(this.back)
end


function BackClick()
	logWarn("返回")
end

function StartClick()
	logWarn("Start")
end

function DialPanel.InitObj(objs)
	
end

--单击事件--
function DialPanel.OnDestroy()
	logWarn("OnDestroy---->>>");
end

